Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[scalardb-cluster] Support Azure Marketplace #275

Merged
merged 4 commits into from
Oct 1, 2024

Conversation

kota2and3kan
Copy link
Collaborator

@kota2and3kan kota2and3kan commented Sep 26, 2024

Description

This PR updates the ScalarDB Cluster Helm Chart to support Azure Marketplace.

To list ScalarDB Cluster on the Azure Marketplace, we have to update our helm chart based on the rules of Azure Marketplace. So, I updated ScalarDB Cluster chart as follows:

  • Add global.azure.* in the values.yaml file.
  • Update spec.template.spec.containers[].image in the deployment.yaml file to pull the container image from ACR for Azure Marketplace.
  • Add the azure-extensions-usage-release-identifier label in the deployment.yaml to trace pods and charge license fees by Azure.

You can see what we need to list products on the Azure Marketplace in the following Azure document.

Also, to reduce the maintenance cost (avoid duplicated maintenance), I updated the current helm chart instead of creating the Azure Marketplace dedicated helm chart. To achieve that, I added the following things:

  • Add global.platform in the values.yaml file.
    • I assume this parameter for switching our helm chart based on platforms (to list on each cloud marketplace, partner catalog or something like that) in the future. In other words, this configuration is not related to Azure Marketplace directly.
    • For example, if you set global.platform=azure, ScalarDB Cluster chart use or add the Azure Marketplace dedicated configurations.
    • We need to do the same thing in the Envoy chart (subchart of ScalarDB Cluster chart). So, I decided to add this parameter as Global Values. We can use this global.platform configuration in both ScalarDB Cluster chart (main chart) and Envoy chart (subchart).

Please take a look!

Related issues and/or PRs

  • I updated the Envoy chart in the following PR.

Changes made

  • Update charts/scalardb-cluster/templates/scalardb-cluster/deployment.yaml to add the Azure Marketplace dedicated configurations.
  • Update charts/scalardb-cluster/values.yaml to add the Azure Marketplace dedicated configurations.
  • charts/scalardb-cluster/README.md and charts/scalardb-cluster/values.schema.json are updated automatically based on values.yaml.

Checklist

  • I have commented my code, particularly in hard-to-understand areas.
  • I have updated the documentation to reflect the changes.
  • Any remaining open issues linked to this PR are documented and up-to-date (Jira, GitHub, etc.).
  • Tests (unit, integration, etc.) have been added for the changes.
  • My changes generate no new warnings.
  • Any dependent changes in other PRs have been merged and published.

Additional notes (optional)

N/A

Release notes

N/A

@kota2and3kan kota2and3kan added improvement scalardb cluster PR for ScalarDB Cluster chart labels Sep 26, 2024
@kota2and3kan kota2and3kan self-assigned this Sep 26, 2024
Comment on lines +27 to +29
{{- if eq .Values.global.platform "azure" }}
azure-extensions-usage-release-identifier: {{ .Release.Name }}
{{- end }}
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment on lines +45 to +49
{{- if eq .Values.global.platform "azure" }}
image: "{{ .Values.global.azure.images.scalardbCluster.registry }}/{{ .Values.global.azure.images.scalardbCluster.image }}:{{ .Values.global.azure.images.scalardbCluster.tag }}"
{{- else }}
image: "{{ .Values.scalardbCluster.image.repository }}:{{ .Values.scalardbCluster.image.tag | default .Chart.AppVersion }}"
{{- end }}
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We must pull container images from ACR for Azure Marketplace instead of our public container registry.
https://learn.microsoft.com/en-us/partner-center/marketplace-offers/azure-container-technical-assets-kubernetes#update-the-helm-chart

@kota2and3kan kota2and3kan requested review from superbrothers, a team, komamitsu, brfrn169, feeblefakie and Torch3333 and removed request for a team September 26, 2024 05:27
Copy link
Contributor

@komamitsu komamitsu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 👍

Copy link

@brfrn169 brfrn169 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thank you!

Copy link

@Torch3333 Torch3333 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you!

Copy link
Contributor

@feeblefakie feeblefakie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thank you!

@feeblefakie feeblefakie merged commit 52e3a65 into main Oct 1, 2024
14 checks passed
@feeblefakie feeblefakie deleted the support-azure-marketplace-scalardb-cluster branch October 1, 2024 08:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement scalardb cluster PR for ScalarDB Cluster chart
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants